﻿/*
    Copyright (C) <2007-2013> Kay Diefenthal

    SimpleRadio is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    SimpleRadio is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with SimpleRadio.  If not, see <http://www.gnu.org/licenses/>.
*/
using System;
using Microsoft.MediaCenter.UI;

namespace SimpleRadio
{
    /// <summary>
    /// <see cref="SortFilter"/> Class.
    /// </summary>
    public class SortFilter : ModelItem
    {
        #region Private Fields

        private SortFilterTypes _sortFilterTypes;

        #endregion

        #region Contructors

        /// <summary>
        /// Initialize a new Instance of <see cref="SortFilter"/> Class.
        /// </summary>
        /// <param name="owner">owner <seealso cref="Microsoft.MediaCenter.UI.IModelItemOwner"/></param>
        /// <param name="description">description <seealso cref="System.String"/></param>
        /// <param name="sortFilterTypes">sortFilterTypes <seealso cref="SortFilterTypes"/></param>
        public SortFilter(IModelItemOwner owner, String description, SortFilterTypes sortFilterTypes)
            : base(owner, description)
        {
            Description = description;
            _sortFilterTypes = sortFilterTypes;
        }

        #endregion

        #region Properties

        /// <summary>
        /// The SortFilter Type 
        /// </summary>
        public SortFilterTypes SortFilterType
        {
            get { return _sortFilterTypes; }
            set
            {
                if (_sortFilterTypes != value)
                {
                    _sortFilterTypes = value; FirePropertyChanged("SortFilterType");
                }
            }
        }
        #endregion
    }
}